*Replication do-file in Stata for Hale & Peshkopia, "Public-Diplomacy-Dissonant Events and Country Favorability," Foreign Policy Analysis, 20250622


use "Data_Replication_Hale-Peshkopia_FPA_20250623.dta", clear



**********************************************************************
***************** EXPERIMENT 1: FAVORABILITY OF US *******************
**********************************************************************

* Create variables

generate FavUS=EFavUS if RAND1==1
replace FavUS=CFavUS if RAND1==2 
* Note: In the original data, RAND1=1 = treatment and RAND1=2 = control. For the reported analysis, we recode so that the control is 0.
recode RAND1 (1=1) (2=0), gen(treatmente1)


********************* ALBANIA *****************************************


*Graph of treatment effect on US favorability score, with 95% CI

reg FavUS i.treatmente1 if Albania==1
margins treatmente1
marginsplot, recast(scatter) ylabel(2 "2" 2.1 "2.1" 2.2 "2.2" 2.3 "2.3" 2.4 "2.4" 2.5 "2.5", angle(horizontal) labsize(medium)) xlabel(0 "Control" 1 "Trump") title("{bf:a. Albania}") ytitle("Avg US favorability, 0-3") xtitle("") yscale(range(2 2.5)) graphr(color(white)) xscale(range(-.5 1.5)) saving(GTfigE1alb20250623, replace)

*Table E1 in Online Appendix

eststo clear

regress FavUS treatmente1 if Albania==1
eststo: margins, dydx(*)
ologit FavUS treatmente1 if Albania==1
eststo: margins, dydx(*)
regress FavUS treatmente1 Age Sex EdYears City if Albania==1
eststo: margins, dydx(*)
ologit FavUS treatmente1 Age Sex EdYears City if Albania==1
eststo: margins, dydx(*)

esttab using GTtabE1alb20250623.rtf, compress b(%9.2f) se star(+ 0.1 * 0.05 ** 0.01) coeflabel(treatmente1 "Trump mention" Age "Age" Sex "Female" EdYears "Years education" City "Urban") mtitles("OLS" "ologit" "OLS" "ologit") title("Table X. Average marginal effects of Trump mention on 4-point scale of U.S. favorability in Albania only, OLS and ordinal logistic models") addnote("") fonttbl(\f0\fnil Times New Roman; ) replace

eststo clear



********************* KOSOVO *****************************************


*Graph of treatment effect on US favorability score, with 95% CI

reg FavUS i.treatmente1 if Kosovo==1
margins treatmente1
marginsplot, recast(scatter) ylabel(2.2 "2.2" 2.3 "2.3" 2.4 "2.4" 2.5 "2.5" 2.6 "2.6" 2.7 "2.7" 2.8 "2.8" 2.9 "2.9", angle(horizontal) labsize(medium)) xlabel(0 "Control" 1 "Trump") title("{bf:b. Kosovo}") ytitle("Avg US favorability, 0-3") xtitle("") yscale(range(2.2 2.9)) graphr(color(white)) xscale(range(-.5 1.5)) saving(GTfigE1kos20250623, replace)

*Table E2 in Online Appendix

eststo clear

regress FavUS treatmente1 if Kosovo==1
eststo: margins, dydx(*)
ologit FavUS treatmente1 if Kosovo==1
eststo: margins, dydx(*)
regress FavUS treatmente1 Age Sex EdYears City EthSerb if Kosovo==1
eststo: margins, dydx(*)
ologit FavUS treatmente1 Age Sex EdYears City EthSerb if Kosovo==1
eststo: margins, dydx(*)

esttab using GTtabE1kos20250623.rtf, compress b(%9.2f) se star(+ 0.1 * 0.05 ** 0.01) coeflabel(treatmente1 "Trump mention" Age "Age" Sex "Female" EdYears "Years education" City "Urban" EthSerb "Ethnic Serb") mtitles("OLS" "ologit" "OLS" "ologit") title("Table X. Average marginal effects of Trump mention on 4-point scale of U.S. favorability in Kosovo only, OLS and ordinal logistic models") addnote("") fonttbl(\f0\fnil Times New Roman; ) replace

eststo clear



********************* SERBIA *****************************************


*Graph of treatment effect on US favorability score, with 95% CI

reg FavUS i.treatmente1 if Serbia==1
margins treatmente1
marginsplot, recast(scatter) ylabel(1.9 "1.9" 1.95 "1.95" 2.0 "2.0" 2.05 "2.05" 2.1 "2.1", angle(horizontal) labsize(medium)) xlabel(0 "Control" 1 "Trump") title("{bf:c. Serbia}") ytitle("Avg US favorability, 0-3") xtitle("") yscale(range(1.9 2.1)) graphr(color(white)) xscale(range(-.5 1.5)) saving(GTfigE1ser20250623, replace)

*Table E3 in Online Appendix

eststo clear

regress FavUS treatmente1 if Serbia==1
eststo: margins, dydx(*)
ologit FavUS treatmente1 if Serbia==1
eststo: margins, dydx(*)
regress FavUS treatmente1 Age Sex EdYears City if Serbia==1
eststo: margins, dydx(*)
ologit FavUS treatmente1 Age Sex EdYears City if Serbia==1
eststo: margins, dydx(*)

esttab using GTtabE1ser20250623.rtf, compress b(%9.2f) se star(+ 0.1 * 0.05 ** 0.01) coeflabel(treatmente1 "Trump mention" Age "Age" Sex "Female" EdYears "Years education" City "Urban") mtitles("OLS" "ologit" "OLS" "ologit") title("Table X. Average marginal effects of Trump mention on 4-point scale of U.S. favorability in Serbia only, OLS and ordinal logistic models") addnote("") fonttbl(\f0\fnil Times New Roman; ) replace

eststo clear




************ Figure 1: Combined graphs for Albania, Kosovo, Serbia *************

gr combine GTfigE1alb20250623.gph GTfigE1kos20250623.gph GTfigE1ser20250623.gph, col(3) iscale(1.7) xsize(4) ysize(1.5) title("{bf:Results from US favorability experiment}", size(vhuge)) graphr(color(white)) saving(GTfigE1combined20250623, replace)


************ Table G1 in Online Appendix: Difference with Serbia in Experiment 1 is statistically significant. Note: Uses clustered standard errors (by Country)

eststo clear

regress FavUS c.treatmente1##c.Serbia Age Sex EdYears City, cluster(Country)
eststo: margins, dydx(*)

ologit FavUS c.treatmente1##c.Serbia Age Sex EdYears City, cluster(Country)
eststo: margins, dydx(*)

esttab using GTtabE1pooledserbsig20250623.rtf, compress b(%9.2f) se star(+ 0.1 * 0.05 ** 0.01) coeflabel(treatmente1 "Trump mention" c.treatmente1#c.Serbia "Trump X Serbia" Age "Age" Sex "Female" EdYears "Years education" City "Urban") mtitles("OLS" "ologit") title("Table X. Average marginal effects of Trump mention on 4-point scale of U.S. favorability in Albania, Kosovo, and Serbia, OLS and ordinal logistic models") addnote("") fonttbl(\f0\fnil Times New Roman; ) replace

eststo clear



**********************************************************************
************************ EXPERIMENT 2: US vs EU **********************
**********************************************************************

* Create variables

*Note: A binary variable is the dependent variable in the reported analysis because this has the clearest-cut substantive meaning relevant for our theory: whether someone would side with US or not. But in all main results tables in the Online Appendix, results using the full three-point scale as the dependent variable are also presented as a robustness check.

*Note: Rallyx3 DV: 1=US, 0=neutral, -1=EU. Rallyx2: 1=US, 0=not
generate Rallyx3=RallyTr if RAND2==1
replace Rallyx3=RallyUS if RAND2==2 
generate Rallyx2=1 if Rallyx3==1
replace Rallyx2=0 if Rallyx3==0 | Rallyx3==-1

*Note: The treatment variable in the dataset recoded so that the treatment is 1 and the control 0
recode RAND2 (1=1) (2=0), gen(treatmente2)


********************* ALBANIA *****************************************


*Graph of treatment effect on likelihood of siding with US, with 95% CI

reg Rallyx2 i.treatmente2 if Albania==1
margins treatmente2
marginsplot, recast(scatter) ylabel(.1 ".1" .15 ".15" .2 ".2" .25 ".25" .3 ".3", angle(horizontal) labsize(medium)) xlabel(0 "Control" 1 "Trump") title("{bf:a. Albania}") ytitle("Probability of siding with US") xtitle("") yscale(range(.1 .3)) graphr(color(white)) xscale(range(-.5 1.5)) saving(GTfigE2alb20250623, replace)


*Table E4 in Online Appendix

eststo clear

regress Rallyx2 treatmente2 if Albania==1
eststo: margins, dydx(*)
regress Rallyx3 treatmente2 if Albania==1
eststo: margins, dydx(*)
logit Rallyx2 treatmente2 if Albania==1
eststo: margins, dydx(*)
ologit Rallyx3 treatmente2 if Albania==1
eststo: margins, dydx(*)
regress Rallyx2 treatmente2 Age Sex EdYears City if Albania==1
eststo: margins, dydx(*)
regress Rallyx3 treatmente2 Age Sex EdYears City if Albania==1
eststo: margins, dydx(*)
logit Rallyx2 treatmente2 Age Sex EdYears City if Albania==1
eststo: margins, dydx(*)
ologit Rallyx3 treatmente2 Age Sex EdYears City if Albania==1
eststo: margins, dydx(*)

esttab using GTtabE2alb20250623.rtf, compress b(%9.2f) se star(+ 0.1 * 0.05 ** 0.01) coeflabel(treatmente2 "Trump mention" Age "Age" Sex "Female" EdYears "Years education" City "Urban") mtitles("binary OLS" "scale OLS" "binary logit" "scale ologit" "binary OLS" "scale OLS" "binary logit" "scale ologit") title("Table X. Average marginal effects of Trump mention on probability of siding with US vs EU in Albania only, with binary and 3-point-scale measures of the dependent variable, OLS, logit, and ordinal logistic models") addnote("") fonttbl(\f0\fnil Times New Roman; ) replace

eststo clear



********************* KOSOVO *****************************************


*Graph of treatment effect on likelihood of siding with US, with 95% CI

reg Rallyx2 i.treatmente2 if Kosovo==1
margins treatmente2
marginsplot, recast(scatter) ylabel(.1 ".1" .2 ".2" .3 ".3" .4 ".4" .5 ".5", angle(horizontal) labsize(medium)) xlabel(0 "Control" 1 "Trump") title("{bf:b. Kosovo}") ytitle("Probability of siding with US") xtitle("") yscale(range(.1 .5)) graphr(color(white)) xscale(range(-.5 1.5)) saving(GTfigE2kos20250623, replace)


*Table E5 in Online Appendix

eststo clear

regress Rallyx2 treatmente2 if Kosovo==1
eststo: margins, dydx(*)
regress Rallyx3 treatmente2 if Kosovo==1
eststo: margins, dydx(*)
logit Rallyx2 treatmente2 if Kosovo==1
eststo: margins, dydx(*)
ologit Rallyx3 treatmente2 if Kosovo==1
eststo: margins, dydx(*)
regress Rallyx2 treatmente2 Age Sex EdYears City EthSerb if Kosovo==1
eststo: margins, dydx(*)
regress Rallyx3 treatmente2 Age Sex EdYears City EthSerb if Kosovo==1
eststo: margins, dydx(*)
logit Rallyx2 treatmente2 Age Sex EdYears City EthSerb if Kosovo==1
eststo: margins, dydx(*)
ologit Rallyx3 treatmente2 Age Sex EdYears City EthSerb if Kosovo==1
eststo: margins, dydx(*)

esttab using GTtabE2kos20250623.rtf, compress b(%9.2f) se star(+ 0.1 * 0.05 ** 0.01) coeflabel(treatmente2 "Trump mention" Age "Age" Sex "Female" EdYears "Years education" City "Urban" EthSerb "Ethnic Serb") mtitles("binary OLS" "scale OLS" "binary logit" "scale ologit" "binary OLS" "scale OLS" "binary logit" "scale ologit") title("Table X. Average marginal effects of Trump mention on probability of siding with US vs EU in Kosovo only, with binary and 3-point-scale measures of the dependent variable, OLS, logit, and ordinal logistic models") addnote("") fonttbl(\f0\fnil Times New Roman; ) replace

eststo clear



********************* SERBIA *****************************************


*Graph of treatment effect on likelihood of siding with US, with 95% CI

reg Rallyx2 i.treatmente2 if Serbia==1
margins treatmente2
marginsplot, recast(scatter) ylabel(0 "0" .01 ".01" .02 ".02" .03 ".03", angle(horizontal) labsize(medium)) xlabel(0 "Control" 1 "Trump") title("{bf:c. Serbia}") ytitle("Probability of siding with US") xtitle("") yscale(range(0 .03)) graphr(color(white)) xscale(range(-.5 1.5)) saving(GTfigE2ser20250623, replace)


*Table E6 in Online Appendix

eststo clear

regress Rallyx2 treatmente2 if Serbia==1
eststo: margins, dydx(*)
regress Rallyx3 treatmente2 if Serbia==1
eststo: margins, dydx(*)
logit Rallyx2 treatmente2 if Serbia==1
eststo: margins, dydx(*)
ologit Rallyx3 treatmente2 if Serbia==1
eststo: margins, dydx(*)
regress Rallyx2 treatmente2 Age Sex EdYears City if Serbia==1
eststo: margins, dydx(*)
regress Rallyx3 treatmente2 Age Sex EdYears City if Serbia==1
eststo: margins, dydx(*)
logit Rallyx2 treatmente2 Age Sex EdYears City if Serbia==1
eststo: margins, dydx(*)
ologit Rallyx3 treatmente2 Age Sex EdYears City if Serbia==1
eststo: margins, dydx(*)

esttab using GTtabE2ser20250623.rtf, compress b(%9.2f) se star(+ 0.1 * 0.05 ** 0.01) coeflabel(treatmente2 "Trump mention" Age "Age" Sex "Female" EdYears "Years education" City "Urban") mtitles("binary OLS" "scale OLS" "binary logit" "scale ologit" "binary OLS" "scale OLS" "binary logit" "scale ologit") title("Table X. Average marginal effects of Trump mention on probability of siding with US vs EU in Serbia only, with binary and 3-point-scale measures of the dependent variable, OLS, logit, and ordinal logistic models") addnote("") fonttbl(\f0\fnil Times New Roman; ) replace

eststo clear



*******************************************************************************

* Figure 2: Combined graph for Albania, Kosovo, Serbia

gr combine GTfigE2alb20250623.gph GTfigE2kos20250623.gph GTfigE2ser20250623.gph, col(4) iscale(1.7) xsize(4) ysize(1.5) title("{bf:Results from rally experiment}", size(vhuge)) graphr(color(white)) saving(GTfigE2combined20250623, replace)



********************************************************************************
****************** Robustness checks reported in Figures 3-4 *******************
********************************************************************************

* Create variables

**** Binary var capturing whether people think Trump policies no worse than Obama
recode OpTrObPo (-2=0) (-1=0) (0=1) (1=1) (2=1), gen(TrNoWorseX2)

**** Binary var capturing whether people think Trump policies better than Obama
recode OpTrObPo (-2=0) (-1=0) (0=0) (1=1) (2=1), gen(TrBetterX2)


* Experiment 1 in Albania and Kosovo-Albanians: 

regress FavUS treatmente1##TrNoWorseX2 if Albania==1
margins, dydx(treatmente1) at(TrNoWorseX2=0 TrNoWorseX2=1)
marginsplot, yline(0) ylabel(-.6 "-.6" -.4 "-.4" -.2 "-.2" 0 "0" .2 ".2",angle(horizontal) labsize(medlarge)) xlabel(0 "Obama better" 1 "Trump no worse",angle(45) labsize(medlarge)) title("{bf:a. Exp. 1: Albania}", size(medlarge)) ytitle("{&Delta} US favorability on 0-3 scale", size(medlarge)) xtitle("") recast(scatter) xscale(range(-.25 1.25)) graphr(color(white)) saving(GTfigE1albhettrnoworse20250623, replace)

regress FavUS treatmente1##TrNoWorseX2 if Kosovo==1 & EthAlbanian==1
margins, dydx(treatmente1) at(TrNoWorseX2=0 TrNoWorseX2=1)
marginsplot, yline(0) ylabel(-.6 "-.6" -.4 "-.4" -.2 "-.2" 0 "0" .2 ".2",angle(horizontal) labsize(medlarge)) xlabel(0 "Obama better" 1 "Trump no worse",angle(45) labsize(medlarge)) title("{bf:b. Exp. 1: Kosovo Albanians}", size(medlarge)) ytitle("") xtitle("") recast(scatter) xscale(range(-.25 1.25)) graphr(color(white)) saving(GTfigE1kosalbhettrnoworse20250623, replace)

* Experiment 2 in Albania and Kosovo (among ethnic Albanians)

regress Rallyx2 treatmente2##TrNoWorseX2 if Albania==1
margins, dydx(treatmente2) at(TrNoWorseX2=0 TrNoWorseX2=1)
marginsplot, yline(0) ylabel(-.6 "-.6" -.4 "-.4" -.2 "-.2" 0 "0" .2 ".2",angle(horizontal) labsize(medlarge)) xlabel(0 "Obama better" 1 "Trump no worse",angle(45) labsize(medlarge)) title("{bf:c. Exp. 2: Albania}", size(medlarge)) ytitle("{&Delta} likelihood of side w/ US", size(medlarge)) xtitle("") recast(scatter) xscale(range(-.25 1.25)) graphr(color(white)) saving(GTfigE2albhettrnoworse20250623, replace)

regress Rallyx2 treatmente2##TrNoWorseX2 if Kosovo==1 & EthAlbanian==1
margins, dydx(treatmente2) at(TrNoWorseX2=0 TrNoWorseX2=1)
marginsplot, yline(0) ylabel(-.6 "-.6" -.4 "-.4" -.2 "-.2" 0 "0" .2 ".2",angle(horizontal) labsize(medlarge)) xlabel(0 "Obama better" 1 "Trump no worse",angle(45) labsize(medlarge)) title("{bf:d. Exp. 2: Kosovo Albanians}", size(medlarge)) ytitle("") xtitle("") recast(scatter) xscale(range(-.25 1.25)) graphr(color(white)) saving(GTfigE2kosalbhettrnoworse20250623, replace)

* Figure 3: combined Albania & Kosovo for Experiments 1-2 by policy views

gr combine GTfigE1albhettrnoworse20250623.gph GTfigE1kosalbhettrnoworse20250623.gph GTfigE2albhettrnoworse20250623.gph GTfigE2kosalbhettrnoworse20250623.gph, col(4) iscale(1) xsize(4) ysize(1.7) title("{bf:Effect of Trump reminder on U.S. favorability (Experiment 1) and probability of siding}" "{bf:with US vs EU (Experiment 2) among people thinking Obama was better for their country}" "{bf:versus among those thinking Trump was no worse, Albania & Kosovo 2018}", size(large)) graphr(color(white)) saving(GTfigE1E2albkosheteffcombined20250623, replace)


* Table E7 for Online Appendix: Albania and Kosovo
eststo clear
regress FavUS c.treatmente1##c.TrNoWorseX2 if Albania==1
eststo: margins, dydx(*)
regress FavUS c.treatmente1##c.TrNoWorseX2 if Kosovo==1 & EthAlbanian==1
eststo: margins, dydx(*)
regress Rallyx2 c.treatmente2##c.TrNoWorseX2 if Albania==1
eststo: margins, dydx(*)
regress Rallyx2 c.treatmente2##c.TrNoWorseX2 if Kosovo==1 & EthAlbanian==1
eststo: margins, dydx(*)
esttab using GTtabE1E2albkosalbheteffcombined20250623.rtf, compress b(%9.2f) se star(+ 0.1 * 0.05 ** 0.01) coeflabel(treatmente1 "Trump treatment 1" treatmente2 "Trump treatment 2" TrNoWorseX2 "Trump no worse" c.treatmente1#c.TrNoWorseX2 "Trump treatment 1 X Trump no worse" c.treatmente2#c.TrNoWorseX2 "Trump treatment 2 X Trump no worse") mtitles("Albania" "Albania" "Kosovo Albanians" "Kosovo Albanians") title("Table X. Average marginal effects of Trump mentions in Experiments 1-2 among people in Albania and Kosovo by whether people perceive Trump policies to be worse than Obama's") addnote("") fonttbl(\f0\fnil Times New Roman; ) replace
eststo clear


* Figure 4: Serbia

regress FavUS treatmente1##TrBetterX2 if Serbia==1
margins, dydx(treatmente1) at(TrBetterX2=0 TrBetterX2=1)
marginsplot, yline(0) ylabel(-.2 "-.2" 0 "0" .2 ".2",angle(horizontal) labsize(medlarge)) xlabel(0 "Obama no worse" 1 "Trump better",labsize(medlarge)) title("a. U.S. favorability on 0-3 scale", size(medlarge)) ytitle("Size of effect", size(medlarge)) xtitle("") recast(scatter) xscale(range(-.25 1.25)) graphr(color(white)) saving(GTfigE1serbhettrbetter20250610, replace)

regress Rallyx2 treatmente2##TrBetterX2 if Serbia==1
margins, dydx(treatmente2) at(TrBetterX2=0 TrBetterX2=1)
marginsplot, yline(0) ylabel(-.2 "-.2" 0 "0" .2 ".2",angle(horizontal) labsize(medlarge)) xlabel(0 "Obama no worse" 1 "Trump better",labsize(medlarge)) title("b. Probability of siding with US", size(medlarge)) ytitle("Size of effect", size(medlarge)) xtitle("") recast(scatter) xscale(range(-.25 1.25)) graphr(color(white)) saving(GTfigE2serbhettrbetter20250610, replace) 

gr combine GTfigE1serbhettrbetter20250610.gph GTfigE2serbhettrbetter20250610.gph, col(2) iscale(1) xsize(3) ysize(1.5) title("{bf:Effect of Trump reminder on U.S. favorability and probability of siding}" "{bf:with US vs EU among people thinking Obama was no worse for their country}" "{bf:and those thinking Trump was better in Serbia in 2018}", size(large)) graphr(color(white)) saving(GTfigE1E2serbheteffcombined20250610, replace)

* Table E8 in Online Appendix: Serbia

eststo clear
regress FavUS c.treatmente1##TrBetterX2 if Serbia==1
eststo: margins, dydx(*)
regress Rallyx2 treatmente2##TrBetterX2 if Serbia==1
eststo: margins, dydx(*)

esttab using GTtabE1E2serbheteffcombined20250623.rtf, compress b(%9.2f) se star(+ 0.1 * 0.05 ** 0.01) coeflabel(treatmente1 "Trump treatment 1" treatmente2 "Trump treatment 2" TrBetterX2 "Trump better" c.treatmente1#c.TrBetterX2 "Trump treatment 1 X Trump better" c.treatmente2#c.TrBetterX2 "Trump treatment 2 X Trump better") mtitles("Experiment 1" "Experiment 2") title("Table X. Average marginal effects of Trump mentions in Experiments 1-2 among people in Albania and Kosovo by whether people perceive Trump policies to be worse than Obama's") addnote("") fonttbl(\f0\fnil Times New Roman; ) replace
eststo clear


********************************************************************************
********************** Balance tables in Online Appendix C *********************
********************************************************************************

* Note: This uses a Stata package for the command balancetable

* Experiment 1:

balancetable (mean if djttreat1==0) (mean if djttreat1==1) (diff djttreat1) Age Sex EdYears City using BalTabGTE1alb20250623.xls if Albania==1, replace

balancetable (mean if djttreat1==0) (mean if djttreat1==1) (diff djttreat1) Age Sex EdYears City using BalTabGTE1kos20250623.xls if Kosovo==1, replace

balancetable (mean if djttreat1==0) (mean if djttreat1==1) (diff djttreat1) Age Sex EdYears City using BalTabGTE1ser20250623.xls if Serbia==1, replace

* Experiment 2:

balancetable (mean if djttreat2==0) (mean if djttreat2==1) (diff djttreat2) Age Sex EdYears City using BalTabGTE2alb20250623.xls if Albania==1, replace

balancetable (mean if djttreat2==0) (mean if djttreat2==1) (diff djttreat2) Age Sex EdYears City using BalTabGTE2kos20250623.xls if Kosovo==1, replace

balancetable (mean if djttreat2==0) (mean if djttreat2==1) (diff djttreat2) Age Sex EdYears City using BalTabGTE2ser20250623.xls if Serbia==1, replace



